import Http from '@/lib/http'

export function page (data) {
  return Http.get(
    '/manage/goods/report/page',
    data,
  )
}

export function queryRecord (reportGoodId) {
  return Http.get(
    `/manage/goods/report/queryRecord?reportGoodId=${reportGoodId}`,
  )
}

export function updateState (reportGoodId, filingState) {
  return Http.post(
    '/manage/goods/report/updateState',
    {
      reportGoodId,
      filingState,
    },
  )
}

export function add (list) {
  return Http.post('/manage/goods/report/add', list)
}

export function auditUp (data) {
  return Http.post('/manage/goods/report/auditUp', {
    ...data,
  })
}

export function auditDown (data) {
  return Http.post('/manage/goods/report/auditDown', {
    ...data,
  })
}

export function detail (reportGoodId) {
  return Http.get(`/manage/goods/report/detail?reportGoodId=${reportGoodId}`)
}

export function modifySku (reportGoodId, sku) {
  return Http.post('/manage/goods/report/modifySku', {
    reportGoodId, sku,
  })
}
